package cn.springboot.erp.entity;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

/**
 * 
 * @TableName sales_returns
 */
@TableName(value ="sales_returns")
@Data
public class SalesReturns implements Serializable {
    /**
     * 退货ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 订单ID，关联销售订单表。
     */
    @TableField(value = "order_id")
    private Integer orderId;

    /**
     * 退货日期
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @TableField(value = "return_date")
    private Date returnDate;

    /**
     * 退货数量
     */
    @TableField(value = "return_quantity")
    private Integer returnQuantity;

    /**
     * 退货原因
     */
    @TableField(value = "return_reason")
    private String returnReason;

    /**
     * 退款状态，0 退款中 1 退款完成 2 退款失败
     */
    @TableField(value = "refund_status")
    private Integer refundStatus;

    /**
     * 退货备注
     */
    @TableField(value = "note")
    private String note;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @TableField(value = "create_time",fill = FieldFill.INSERT)
    private Date createTime;

    /**
     * 更新时间
     */
    @TableField(value = "update_time",fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}